package main

import (
	"encoding/json"
	"fmt"
)

type UserInfo struct {
	Name string
	Age  int
}

func main() {
	str := "{\"Name\":\"Justin\",\"Age\":12}"
	userInfo := &UserInfo{}
	json.Unmarshal([]byte(str), userInfo)
	fmt.Print(userInfo.Name, userInfo.Age)
}